home *** CD-ROM | disk | FTP | other *** search
/ Interactive Media Design Review 1999 / Interactive Media Design Review 1999.iso / pc / allfiles / angry / intro.dir / 00010_Script_credits frame < prev    next >
Text File  |  1999-03-01  |  2KB  |  95 lines

  1. global oldMouseP
  2. global drops
  3. global cursorSpr
  4. global animate
  5. global gravite
  6.  
  7.  
  8. on mouseDown
  9.   
  10.   sprite(5).member = member "quitOFF"
  11.   sprite(6).member = member "creditsOFF"
  12.   go to frame "welcomeBack"
  13. end
  14.  
  15.  
  16. on enterFrame
  17.   
  18.   
  19.   -- main cursor
  20.   
  21.   set mouseP = point(the mouseH, the mouseV)
  22.   
  23.   if inside(mouseP, rect(0, 0, 640, 480)) then cursor 200
  24.   else cursor -1
  25.   
  26.   set diffP = mouseP - oldMouseP
  27.   
  28.   set horiz = getAt(diffP, 1)
  29.   set vert = getAt(diffP, 2)
  30.   
  31.   set drop = TRUE
  32.   
  33.   if horiz < -5 then
  34.     
  35.     if vert < -5 then
  36.       set the member of sprite(cursorSpr) to member "northwest"
  37.     else if vert > 5 then
  38.       set the member of sprite(cursorSpr) to member "southwest"
  39.     else
  40.       set the member of sprite(cursorSpr) to member "west"
  41.     end if
  42.     
  43.   else if horiz > 5 then
  44.     
  45.     if vert < -5 then
  46.       set the member of sprite(cursorSpr) to member "northeast"
  47.     else if vert > 5 then
  48.       set the member of sprite(cursorSpr) to member "southeast"
  49.     else
  50.       set the member of sprite(cursorSpr) to member "east"
  51.     end if
  52.     
  53.   else
  54.     
  55.     if vert < -5 then
  56.       set the member of sprite(cursorSpr) to member "north"
  57.     else if vert > 5 then
  58.       set the member of sprite(cursorSpr) to member "south"
  59.     else  
  60.       set the member of sprite(cursorSpr) to member "stop"
  61.       set drop = FALSE
  62.     end if
  63.     
  64.   end if
  65.   
  66.   set the loc of sprite cursorSpr to mouseP
  67.   
  68.   -- little droplets
  69.   
  70.   repeat with a = 1 to count(drops)
  71.     set doMe = getAt(drops, a)
  72.     check doMe
  73.   end repeat
  74.   
  75.   
  76.   if random(2) = 2 AND drop then
  77.     repeat with a = 1 to count(drops)
  78.       set doMe = getAt(drops, a)
  79.       if not(the pActive of doMe) then
  80.         drop doMe, cursorSpr
  81.         exit repeat
  82.       end if
  83.     end repeat
  84.   end if
  85.   
  86.   
  87.   set oldMouseP = point(the mouseH, the mouseV)
  88.   
  89.   
  90. end
  91.  
  92. on exitFrame
  93.   go to the frame
  94. end
  95.